package com.jerry.template.module.mainpage.find.entity;

import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;

import org.json.JSONException;
import org.json.JSONObject;

import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.List;

/**
 * Created by chenhuan on 2016/5/13.
 */
public class BannerList{



    private String message;


    private DataBean1 data;

    public static BannerList objectFromData(String str){
        return new Gson().fromJson(str, BannerList.class);
    }

    public static BannerList objectFromData(String str, String key){
        try{
            JSONObject jsonObject = new JSONObject(str);
            return new Gson().fromJson(jsonObject.getString(str), BannerList.class);
        }catch(JSONException e){
            e.printStackTrace();
        }
        return null;
    }

    public static List<BannerList> arrayDaPeiRiJiListFromData(String str){
        Type listType = new TypeToken<ArrayList<BannerList>>(){
        }.getType();
        return new Gson().fromJson(str, listType);
    }

    public static List<BannerList> arrayDaPeiRiJiListFromData(String str, String key){
        try{
            JSONObject jsonObject = new JSONObject(str);
            Type listType = new TypeToken<ArrayList<BannerList>>(){
            }.getType();
            return new Gson().fromJson(jsonObject.getString(str), listType);
        }catch(JSONException e){
            e.printStackTrace();
        }
        return new ArrayList();
    }

    public String getMessage(){
        return message;
    }

    public void setMessage(String message){
        this.message = message;
    }

    public DataBean1 getData(){
        return data;
    }

    public void setData(DataBean1 data){
        this.data = data;
    }

    public static class DataBean1{
        private boolean has_more;
        private String tip;
        private boolean has_new_message;
        private double max_time;
        private int min_time;


        private List<DataBean> data;

        public static DataBean objectFromData(String str){
            return new Gson().fromJson(str, DataBean.class);
        }

        public static DataBean objectFromData(String str, String key){
            try{
                JSONObject jsonObject = new JSONObject(str);
                return new Gson().fromJson(jsonObject.getString(str), DataBean.class);
            }catch(JSONException e){
                e.printStackTrace();
            }
            return null;
        }

        public static List<DataBean> arrayDataBeanFromData(String str){
            Type listType = new TypeToken<ArrayList<DataBean>>(){
            }.getType();
            return new Gson().fromJson(str, listType);
        }

        public static List<DataBean> arrayDataBeanFromData(String str, String key){
            try{
                JSONObject jsonObject = new JSONObject(str);
                Type listType = new TypeToken<ArrayList<DataBean>>(){
                }.getType();
                return new Gson().fromJson(jsonObject.getString(str), listType);
            }catch(JSONException e){
                e.printStackTrace();
            }
            return new ArrayList();
        }

        public boolean isHas_more(){
            return has_more;
        }

        public void setHas_more(boolean has_more){
            this.has_more = has_more;
        }

        public String getTip(){
            return tip;
        }

        public void setTip(String tip){
            this.tip = tip;
        }

        public boolean isHas_new_message(){
            return has_new_message;
        }

        public void setHas_new_message(boolean has_new_message){
            this.has_new_message = has_new_message;
        }

        public double getMax_time(){
            return max_time;
        }

        public void setMax_time(double max_time){
            this.max_time = max_time;
        }

        public int getMin_time(){
            return min_time;
        }

        public void setMin_time(int min_time){
            this.min_time = min_time;
        }

        public List<DataBean> getData(){
            return data;
        }

        public void setData(List<DataBean> data){
            this.data = data;
        }

        public static class DataBean{


            private GroupBean group;
            private int type;
            private double display_time;
            private double online_time;
            private List<?> comments;

            public static DataBean objectFromData(String str){
                return new Gson().fromJson(str, DataBean.class);
            }

            public static DataBean objectFromData(String str, String key){
                try{
                    JSONObject jsonObject = new JSONObject(str);
                    return new Gson().fromJson(jsonObject.getString(str), DataBean.class);
                }catch(JSONException e){
                    e.printStackTrace();
                }
                return null;
            }

            public static List<DataBean> arrayDataBeanFromData(String str){
                Type listType = new TypeToken<ArrayList<DataBean>>(){
                }.getType();
                return new Gson().fromJson(str, listType);
            }

            public static List<DataBean> arrayDataBeanFromData(String str, String key){
                try{
                    JSONObject jsonObject = new JSONObject(str);
                    Type listType = new TypeToken<ArrayList<DataBean>>(){
                    }.getType();
                    return new Gson().fromJson(jsonObject.getString(str), listType);
                }catch(JSONException e){
                    e.printStackTrace();
                }
                return new ArrayList();
            }

            public GroupBean getGroup(){
                return group;
            }

            public void setGroup(GroupBean group){
                this.group = group;
            }

            public int getType(){
                return type;
            }

            public void setType(int type){
                this.type = type;
            }

            public double getDisplay_time(){
                return display_time;
            }

            public void setDisplay_time(double display_time){
                this.display_time = display_time;
            }

            public double getOnline_time(){
                return online_time;
            }

            public void setOnline_time(double online_time){
                this.online_time = online_time;
            }

            public List<?> getComments(){
                return comments;
            }

            public void setComments(List<?> comments){
                this.comments = comments;
            }

            public static class GroupBean{
                private String text;
                private String neihan_hot_start_time;
                private int create_time;
                private long id;
                private int favorite_count;
                private int go_detail_count;
                private int user_favorite;
                private int share_type;
                private double max_screen_width_percent;
                private int is_can_share;
                private int category_type;
                private String share_url;
                private int label;
                private String content;
                private int comment_count;
                private String id_str;
                private int media_type;
                private int share_count;
                private int type;
                private int status;
                private int has_comments;
                /**
                 * width : 436
                 * r_height : 561
                 * r_width : 436
                 * url_list : [{"url":"http://p3.pstatp.com/w436/4280002622af884c423"},{"url":"http://pb2.pstatp.com/w436/4280002622af884c423"},{"url":"http://pb3.pstatp.com/w436/4280002622af884c423"}]
                 * uri : w436/4280002622af884c423
                 * height : 561
                 */

                private LargeImageBean large_image;
                private int user_bury;
                private String status_desc;
                private boolean quick_comment;
                /**
                 * user_id : 3351552616
                 * name : 潇洒今生只为缘
                 * followings : 0
                 * ugc_count : 2569
                 * avatar_url : http://tp2.sinaimg.cn/3922473013/50/40040830240/0
                 * followers : 1893
                 * is_following : false
                 * user_verified : false
                 */

                private UserBean user;
                private String neihan_hot_end_time;
                private int user_digg;
                private int online_time;
                private String category_name;
                private boolean category_visible;
                private int bury_count;
                private boolean is_anonymous;
                private int repin_count;
                private double min_screen_width_percent;
                private boolean is_neihan_hot;
                private int digg_count;
                private int has_hot_comments;
                private int image_status;
                private int user_repin;
                private long group_id;
                private LargeImageBean middle_image;
                private int category_id;

                public static GroupBean objectFromData(String str){
                    return new Gson().fromJson(str, GroupBean.class);
                }

                public static GroupBean objectFromData(String str, String key){
                    try{
                        JSONObject jsonObject = new JSONObject(str);
                        return new Gson().fromJson(jsonObject.getString(str), GroupBean.class);
                    }catch(JSONException e){
                        e.printStackTrace();
                    }
                    return null;
                }

                public static List<GroupBean> arrayGroupBeanFromData(String str){
                    Type listType = new TypeToken<ArrayList<GroupBean>>(){
                    }.getType();
                    return new Gson().fromJson(str, listType);
                }

                public static List<GroupBean> arrayGroupBeanFromData(String str, String key){
                    try{
                        JSONObject jsonObject = new JSONObject(str);
                        Type listType = new TypeToken<ArrayList<GroupBean>>(){
                        }.getType();
                        return new Gson().fromJson(jsonObject.getString(str), listType);
                    }catch(JSONException e){
                        e.printStackTrace();
                    }
                    return new ArrayList();
                }

                public String getText(){
                    return text;
                }

                public void setText(String text){
                    this.text = text;
                }

                public String getNeihan_hot_start_time(){
                    return neihan_hot_start_time;
                }

                public void setNeihan_hot_start_time(String neihan_hot_start_time){
                    this.neihan_hot_start_time = neihan_hot_start_time;
                }

                public int getCreate_time(){
                    return create_time;
                }

                public void setCreate_time(int create_time){
                    this.create_time = create_time;
                }

                public long getId(){
                    return id;
                }

                public void setId(long id){
                    this.id = id;
                }

                public int getFavorite_count(){
                    return favorite_count;
                }

                public void setFavorite_count(int favorite_count){
                    this.favorite_count = favorite_count;
                }

                public int getGo_detail_count(){
                    return go_detail_count;
                }

                public void setGo_detail_count(int go_detail_count){
                    this.go_detail_count = go_detail_count;
                }

                public int getUser_favorite(){
                    return user_favorite;
                }

                public void setUser_favorite(int user_favorite){
                    this.user_favorite = user_favorite;
                }

                public int getShare_type(){
                    return share_type;
                }

                public void setShare_type(int share_type){
                    this.share_type = share_type;
                }

                public double getMax_screen_width_percent(){
                    return max_screen_width_percent;
                }

                public void setMax_screen_width_percent(double max_screen_width_percent){
                    this.max_screen_width_percent = max_screen_width_percent;
                }

                public int getIs_can_share(){
                    return is_can_share;
                }

                public void setIs_can_share(int is_can_share){
                    this.is_can_share = is_can_share;
                }

                public int getCategory_type(){
                    return category_type;
                }

                public void setCategory_type(int category_type){
                    this.category_type = category_type;
                }

                public String getShare_url(){
                    return share_url;
                }

                public void setShare_url(String share_url){
                    this.share_url = share_url;
                }

                public int getLabel(){
                    return label;
                }

                public void setLabel(int label){
                    this.label = label;
                }

                public String getContent(){
                    return content;
                }

                public void setContent(String content){
                    this.content = content;
                }

                public int getComment_count(){
                    return comment_count;
                }

                public void setComment_count(int comment_count){
                    this.comment_count = comment_count;
                }

                public String getId_str(){
                    return id_str;
                }

                public void setId_str(String id_str){
                    this.id_str = id_str;
                }

                public int getMedia_type(){
                    return media_type;
                }

                public void setMedia_type(int media_type){
                    this.media_type = media_type;
                }

                public int getShare_count(){
                    return share_count;
                }

                public void setShare_count(int share_count){
                    this.share_count = share_count;
                }

                public int getType(){
                    return type;
                }

                public void setType(int type){
                    this.type = type;
                }

                public int getStatus(){
                    return status;
                }

                public void setStatus(int status){
                    this.status = status;
                }

                public int getHas_comments(){
                    return has_comments;
                }

                public void setHas_comments(int has_comments){
                    this.has_comments = has_comments;
                }

                public LargeImageBean getLarge_image(){
                    return large_image;
                }

                public void setLarge_image(LargeImageBean large_image){
                    this.large_image = large_image;
                }

                public int getUser_bury(){
                    return user_bury;
                }

                public void setUser_bury(int user_bury){
                    this.user_bury = user_bury;
                }

                public String getStatus_desc(){
                    return status_desc;
                }

                public void setStatus_desc(String status_desc){
                    this.status_desc = status_desc;
                }

                public boolean isQuick_comment(){
                    return quick_comment;
                }

                public void setQuick_comment(boolean quick_comment){
                    this.quick_comment = quick_comment;
                }

                public UserBean getUser(){
                    return user;
                }

                public void setUser(UserBean user){
                    this.user = user;
                }

                public String getNeihan_hot_end_time(){
                    return neihan_hot_end_time;
                }

                public void setNeihan_hot_end_time(String neihan_hot_end_time){
                    this.neihan_hot_end_time = neihan_hot_end_time;
                }

                public int getUser_digg(){
                    return user_digg;
                }

                public void setUser_digg(int user_digg){
                    this.user_digg = user_digg;
                }

                public int getOnline_time(){
                    return online_time;
                }

                public void setOnline_time(int online_time){
                    this.online_time = online_time;
                }

                public String getCategory_name(){
                    return category_name;
                }

                public void setCategory_name(String category_name){
                    this.category_name = category_name;
                }

                public boolean isCategory_visible(){
                    return category_visible;
                }

                public void setCategory_visible(boolean category_visible){
                    this.category_visible = category_visible;
                }

                public int getBury_count(){
                    return bury_count;
                }

                public void setBury_count(int bury_count){
                    this.bury_count = bury_count;
                }

                public boolean isIs_anonymous(){
                    return is_anonymous;
                }

                public void setIs_anonymous(boolean is_anonymous){
                    this.is_anonymous = is_anonymous;
                }

                public int getRepin_count(){
                    return repin_count;
                }

                public void setRepin_count(int repin_count){
                    this.repin_count = repin_count;
                }

                public double getMin_screen_width_percent(){
                    return min_screen_width_percent;
                }

                public void setMin_screen_width_percent(double min_screen_width_percent){
                    this.min_screen_width_percent = min_screen_width_percent;
                }

                public boolean isIs_neihan_hot(){
                    return is_neihan_hot;
                }

                public void setIs_neihan_hot(boolean is_neihan_hot){
                    this.is_neihan_hot = is_neihan_hot;
                }

                public int getDigg_count(){
                    return digg_count;
                }

                public void setDigg_count(int digg_count){
                    this.digg_count = digg_count;
                }

                public int getHas_hot_comments(){
                    return has_hot_comments;
                }

                public void setHas_hot_comments(int has_hot_comments){
                    this.has_hot_comments = has_hot_comments;
                }

                public int getImage_status(){
                    return image_status;
                }

                public void setImage_status(int image_status){
                    this.image_status = image_status;
                }

                public int getUser_repin(){
                    return user_repin;
                }

                public void setUser_repin(int user_repin){
                    this.user_repin = user_repin;
                }

                public long getGroup_id(){
                    return group_id;
                }

                public void setGroup_id(long group_id){
                    this.group_id = group_id;
                }

                public LargeImageBean getMiddle_image(){
                    return middle_image;
                }

                public void setMiddle_image(LargeImageBean middle_image){
                    this.middle_image = middle_image;
                }

                public int getCategory_id(){
                    return category_id;
                }

                public void setCategory_id(int category_id){
                    this.category_id = category_id;
                }

                public static class LargeImageBean{
                    private int width;
                    private int r_height;
                    private int r_width;
                    private String uri;
                    private int height;
                    /**
                     * url : http://p3.pstatp.com/w436/4280002622af884c423
                     */

                    private List<UrlListBean> url_list;

                    public static LargeImageBean objectFromData(String str){
                        return new Gson().fromJson(str, LargeImageBean.class);
                    }

                    public static LargeImageBean objectFromData(String str, String key){
                        try{
                            JSONObject jsonObject = new JSONObject(str);
                            return new Gson().fromJson(jsonObject.getString(str), LargeImageBean.class);
                        }catch(JSONException e){
                            e.printStackTrace();
                        }
                        return null;
                    }

                    public static List<LargeImageBean> arrayLargeImageBeanFromData(String str){
                        Type listType = new TypeToken<ArrayList<LargeImageBean>>(){
                        }.getType();
                        return new Gson().fromJson(str, listType);
                    }

                    public static List<LargeImageBean> arrayLargeImageBeanFromData(String str, String key){
                        try{
                            JSONObject jsonObject = new JSONObject(str);
                            Type listType = new TypeToken<ArrayList<LargeImageBean>>(){
                            }.getType();
                            return new Gson().fromJson(jsonObject.getString(str), listType);
                        }catch(JSONException e){
                            e.printStackTrace();
                        }
                        return new ArrayList();
                    }

                    public int getWidth(){
                        return width;
                    }

                    public void setWidth(int width){
                        this.width = width;
                    }

                    public int getR_height(){
                        return r_height;
                    }

                    public void setR_height(int r_height){
                        this.r_height = r_height;
                    }

                    public int getR_width(){
                        return r_width;
                    }

                    public void setR_width(int r_width){
                        this.r_width = r_width;
                    }

                    public String getUri(){
                        return uri;
                    }

                    public void setUri(String uri){
                        this.uri = uri;
                    }

                    public int getHeight(){
                        return height;
                    }

                    public void setHeight(int height){
                        this.height = height;
                    }

                    public List<UrlListBean> getUrl_list(){
                        return url_list;
                    }

                    public void setUrl_list(List<UrlListBean> url_list){
                        this.url_list = url_list;
                    }

                    public static class UrlListBean{
                        private String url;

                        public static UrlListBean objectFromData(String str){
                            return new Gson().fromJson(str, UrlListBean.class);
                        }

                        public static UrlListBean objectFromData(String str, String key){
                            try{
                                JSONObject jsonObject = new JSONObject(str);
                                return new Gson().fromJson(jsonObject.getString(str), UrlListBean.class);
                            }catch(JSONException e){
                                e.printStackTrace();
                            }
                            return null;
                        }

                        public static List<UrlListBean> arrayUrlListBeanFromData(String str){
                            Type listType = new TypeToken<ArrayList<UrlListBean>>(){
                            }.getType();
                            return new Gson().fromJson(str, listType);
                        }

                        public static List<UrlListBean> arrayUrlListBeanFromData(String str, String key){
                            try{
                                JSONObject jsonObject = new JSONObject(str);
                                Type listType = new TypeToken<ArrayList<UrlListBean>>(){
                                }.getType();
                                return new Gson().fromJson(jsonObject.getString(str), listType);
                            }catch(JSONException e){
                                e.printStackTrace();
                            }
                            return new ArrayList();
                        }

                        public String getUrl(){
                            return url;
                        }

                        public void setUrl(String url){
                            this.url = url;
                        }
                    }
                }

                public static class UserBean{
                    private long user_id;
                    private String name;
                    private int followings;
                    private int ugc_count;
                    private String avatar_url;
                    private int followers;
                    private boolean is_following;
                    private boolean user_verified;

                    public static UserBean objectFromData(String str){
                        return new Gson().fromJson(str, UserBean.class);
                    }

                    public static UserBean objectFromData(String str, String key){
                        try{
                            JSONObject jsonObject = new JSONObject(str);
                            return new Gson().fromJson(jsonObject.getString(str), UserBean.class);
                        }catch(JSONException e){
                            e.printStackTrace();
                        }
                        return null;
                    }

                    public static List<UserBean> arrayUserBeanFromData(String str){
                        Type listType = new TypeToken<ArrayList<UserBean>>(){
                        }.getType();
                        return new Gson().fromJson(str, listType);
                    }

                    public static List<UserBean> arrayUserBeanFromData(String str, String key){
                        try{
                            JSONObject jsonObject = new JSONObject(str);
                            Type listType = new TypeToken<ArrayList<UserBean>>(){
                            }.getType();
                            return new Gson().fromJson(jsonObject.getString(str), listType);
                        }catch(JSONException e){
                            e.printStackTrace();
                        }
                        return new ArrayList();
                    }

                    public long getUser_id(){
                        return user_id;
                    }

                    public void setUser_id(long user_id){
                        this.user_id = user_id;
                    }

                    public String getName(){
                        return name;
                    }

                    public void setName(String name){
                        this.name = name;
                    }

                    public int getFollowings(){
                        return followings;
                    }

                    public void setFollowings(int followings){
                        this.followings = followings;
                    }

                    public int getUgc_count(){
                        return ugc_count;
                    }

                    public void setUgc_count(int ugc_count){
                        this.ugc_count = ugc_count;
                    }

                    public String getAvatar_url(){
                        return avatar_url;
                    }

                    public void setAvatar_url(String avatar_url){
                        this.avatar_url = avatar_url;
                    }

                    public int getFollowers(){
                        return followers;
                    }

                    public void setFollowers(int followers){
                        this.followers = followers;
                    }

                    public boolean isIs_following(){
                        return is_following;
                    }

                    public void setIs_following(boolean is_following){
                        this.is_following = is_following;
                    }

                    public boolean isUser_verified(){
                        return user_verified;
                    }

                    public void setUser_verified(boolean user_verified){
                        this.user_verified = user_verified;
                    }
                }
            }
        }
    }
}
